% ascii_list.m  2/22/2013  Parker MacCready
%
% list for GIS

clear; close all
addpath('~/Documents/tools/alpha');
[Tdir] = toolstart;
infile = 'max_speed.nc';

lon = nc_varget(infile,'lon');
lat = nc_varget(infile,'lat');
max_speed = nc_varget(infile,'max_speed');
header = size(lon);

lon = flipud(lon); lon = lon(:);
lat = flipud(lat); lat = lat(:);
speed = flipud(max_speed); speed = speed(:);

spd = [lon,lat,speed];
spd(isnan(spd)) = -9999;

%spd = spd(1:10,:);

SaveAsciiRaster(spd,header);

